<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
</head>
<body>
    
<?php
    /*session_start();		
    ob_start();*/
    $no_reg=$_GET["anggota"];
    include('class.mysql.php');
    $mydb = new mysql();
    $connection = $mydb->Connect();
    $stTemp='<table class="box" width="100%">';
    $stTemp.='<tr><th colspan="8">PROGRAM KELOMPOK KERJA</th></tr></table>';
    {
        //program bg reguler
        $sql="select tahun,nilai from program where no_reg='$no_reg' and nama_program='reguler' order by urut";
        //echo "$sql";	
        $query = $mydb->Query($sql);
        $num = $mydb->FetchNum($query);
        //$kabupaten[]="Pilih kota2";
        while($array= mysql_fetch_row($query))
        {
            $tahunx[]=$array[0];
            $nilaix[]=$array[1];
        }
        //echo $data.$kabupaten[2];
        //ob_end_flush();
        // onchange="ChangeNoReg_updatelist(this.value)"
	$stTemp .= '<table class="box" align="center">'.'<tbody><tr>'.'<th rowspan="2">Tahun</th>'.'<th colspan="2">PROGRAM BLOCK GRANT REGULER</th>'.'</tr><tr>';
	$stTemp .= '<th>Jumlah Block Grant Reguler</th></tr>';
        $i=0;
        while($tahunx[$i]!='')
        {
	    $stTemp.='<tr>';
	        $stTemp.='</tr><tr><td align="center" nowrap="">'.$tahunx[$i].'</td>';
                $stTemp.='<td align="center">'.$nilaix[$i].'</td>';
	    $stTemp.='</tr>';
            $i++;
        }
        $stTemp.='</table>';
        //program bg fasilitas tik
        $sql="select tahun,fasilitas,jumlah from program where no_reg='$no_reg' and nama_program='tik' order by urut";
        //echo "$sql";	
        $query = $mydb->Query($sql);
        $num = $mydb->FetchNum($query);
        //$kabupaten[]="Pilih kota2";
        while($array= mysql_fetch_row($query))
        {
            $tahun2x[]=$array[0];
            $fasilitas2x[]=$array[1];
            $jumlah2x[]=$array[2];
        }
        //echo $data.$kabupaten[2];
        //ob_end_flush();
        // onchange="ChangeNoReg_updatelist(this.value)"
	$stTemp .= '<table class="box" align="center">'.'<tbody><tr>'.'<th rowspan="2">Tahun</th>'.'<th colspan="3">PROGRAM BLOCK GRANT FASILITAS TIK</th>'.'</tr><tr>';
	$stTemp .= '<th>Jenis Fasilitas TIK</th><th>Jumlah</th></tr>';
        $i=0;
        while($tahun2x[$i]!='')
        {
	    $stTemp.='<tr>';
	        $stTemp.='</tr><tr><td align="center" nowrap="">'.$tahun2x[$i].'</td>';
                $stTemp.='<td align="center">'.$fasilitas2x[$i].'</td>';
                $stTemp.='<td align="center">'.$jumlah2x[$i].'</td>';                
	    $stTemp.='</tr>';
            $i++;
        }
        $stTemp.='</table>';
        //program bg reguler
        $sql="select tahun from program where no_reg='$no_reg' and nama_program='bermutu' order by urut";
        //echo "$sql";	
        $query = $mydb->Query($sql);
        $num = $mydb->FetchNum($query);
        //$kabupaten[]="Pilih kota2";
        while($array= mysql_fetch_row($query))
        {
            $tahun3x[]=$array[0];
        }
        //echo $data.$kabupaten[2];
        //ob_end_flush();
        // onchange="ChangeNoReg_updatelist(this.value)"
	$stTemp .= '<table class="box" align="center">'.'<tbody><tr>'.'<th rowspan="2">Tahun</th>'.'<th colspan="2">PROGRAM BERMUTU</th>'.'</tr><tr>';
	$stTemp .= '<th>Status Program Bermutu</th></tr>';
        $i=0;
        while($tahun3x[$i]!='')
        {
	    $stTemp.='<tr>';
	        $stTemp.='</tr><tr><td align="center" nowrap="">'.$tahun3x[$i].'</td>';
                $stTemp.='<td align="center">Menerima</td>';
	    $stTemp.='</tr>';
            $i++;
        }
        $stTemp.='</table>';
    }
    echo    $stTemp;
?>
</body>

